<div class="boxes">

	<div class="hd"><!--{tool bar}-->
<?php if( is_login() ):?>	
	<?=_sess('u2_nickname');?>,<?=_text('app_system_welcome')?><?=$this->config->item('site_name')?></div>
	<div class="bd login_end">
		
			<div class="l"><img src="<?=show_user_icon()?>" class="icon"/>
			</div>
			<div class="r">
				<img src="/static/images/arrow_collapse.gif"><a href="/user/setting/"><?=_text('user_setting_title');?></a>&nbsp;<img src="/static/images/arrow_collapse.gif"><a href="/user/uploadpic/"><?=_text('user_uploadpic_title');?></a>
			</div>
			
	
	</div>
<?php else:?>
	<?=_text('system_login')?></div>
	<div class="bd">
		<form action="/user/login/save" method="post" id="widgets_login">
		<?=_text('user_login_email');?>:<br/>
		<input type="text" class="text" name="email" id="email" id="email"><br/>
		<?=_text('user_login_pass')?>:<br/>
		<input type="password" class="text" name="psw" id="psw"><br/>
		<input type="checkbox" value="1" name="remember" id="remember"  />&nbsp;<label for="remember"><?=_text('system_remember_me')?></label>&nbsp;<a href="/user/forgetpass/">找回密码</a><br/><br/>
		<input type="submit" value="<?=_text('system_login')?>" class="button" id="submit_button" > <!--onclick="check_mail(email,widgets_login)"-->
		</form>
	</div>
	<script>
	if( Cookie.get('u2_email') && Cookie.get('u2_password_md5') )
	{
		$('email').value = Cookie.get('u2_email');
		$('psw').value = Cookie.get('u2_password_md5');
		$('remember').checked = true;
		$('submit_button').value = 'Login...';
		$('widgets_login').submit();

	}

	</script>
<?php endif;?>
</div>
<br clear="all">